﻿ <!----------------------------------
            Customize Task
            -------------------------------->
            <div class="custom-task">
            
            <div class="main-content">
                 <div class="top-btn-per clearfix">
                <div class="back-button"><a href="javascript:void(0);" id="btnBackTaskCustomize"><img alt="back-btn" src="@Url.Content("~/images/customTask-img/back-btn.png")" class="back-btn">
                <div class="back-mob-btn"><span class="glyphicon glyphicon-chevron-left"></span> Back</div>
                </a></div>
                <div class="ques-button"><a href="javascript:void(0);"><img class="ques-bt" src="@Url.Content("~/images/customTask-img/ques-btn.png")" alt="ques-btn">
                <img class="mobques-bt" src="@Url.Content("~/images/customTask-img/mobques-btn.png")" alt="ques-btn">
                </a></div>
              </div>
                  <div class="personalization-data customize-data clearfix">
                  <div class="group-mtt-outer">
                    <div class="panel-group-mtt clearfix">
                      <div class="media"> <a class="ACR-img" href="javascript:void(0);"> <img alt="task-img1" id="imgTaskCustomize" src="@Url.Content("~/images/customTask-img/customize-img.png")"> </a>
                        <div class="media-body">
                        <div class="left-group-panel">
                          <h4 class="media-heading titleFeature" id="titleTaskCustomize"></h4>
                          <div class="icon-mtt clearfix">
                            <div class="star pull-left"><img alt="star-i3" id="imgPriorityTaskCustomize" src="@Url.Content("~/images/customTask-img/star.png")"></div>
                            
                          </div>
                          <p id="descriptionTaskCustomize">Lorem ipsum dolor sit amet, consectetur eiusmod tempor incididunt ut 
labore et Lorem ipsum dolor sit amet</p>
                        </div>
                        
                        </div>
                      </div>
                    </div>
                    
                    
                  </div>
                  <br />
                      
                     @{
                  var sessionValue = "";
                  if (Session[HomeCareLibrary.Constants.SessionConstants.MODE]!=null)
                  {
                      sessionValue = Session[HomeCareLibrary.Constants.SessionConstants.MODE].ToString();
                  }
                  else{
                      sessionValue = "";
                  }
                      <input type="hidden" value="@sessionValue" id="hdnSessionValueTask" />
              }
                        <div aria-hidden="true" aria-labelledby="mySmallModalLabel" role="dialog" tabindex="-1" id="taskCustomizeDeleteTask" class="modal fade bs-modal-sm" >
                                            <div class="modal-dialog modal-sm">
                                                <div class="modal-content">
                                                    <div class="modal-body">
                                                        Are you sure you want to delete your Task?
                                                    </div>
                                                    <div class="modal-footer">
                                                      <a href="@Url.Action("DeleteTask", "Mtt", new {id=ViewBag.getTaskCode})" class="btn btn-default">Ok </a>
                                                        <button data-dismiss="modal" class="btn btn-default" type="button">Cancel</button>



                                                    </div>
                                                </div>
                                                <!-- /.modal-content -->
                                            </div>
                                            <!-- /.modal-dialog -->
                                        </div>   
                  <div class="customize-task">
                  <table class="table">
       
        <tbody>
          <tr>
            <td>&nbsp;</td>
            <td>Change this task</td>
                
            <td>
                 <input type="hidden"  id="hdnTaskCode" value="@ViewBag.getTaskCode" />
                <a id="taskChangeClick" href="javascript:void(0);"><img src="@Url.Content("~/images/customTask-img/change-btn.png")" alt="Change Task" /></a>

            </td>
            <td>&nbsp;</td>
          </tr>
          <tr>
            <td>&nbsp;</td>
            <td>Delete this task, <br>
but keep <b class="titleFeature"></b></td>
            <td><a href="javascript:void(0);" data-toggle="modal" data-target="#taskCustomizeDeleteTask"><img src="@Url.Content("~/images/customTask-img/delete-task.png")" alt="" /></a></td>
            <td>&nbsp;</td>
          </tr>
          <tr>
            <td>&nbsp;</td>
            <td>Delete  <b class="titleFeature"></b> completely </td>
            <td><a href="#" ><img src="@Url.Content("~/images/customTask-img/delete-entire.png")" alt="" /></a></td>
            <td>&nbsp;</td>
          </tr>
        </tbody>
      </table>
                  </div>
                  
                    </div>
                  
                
              
            </div>
            </div>

            
            <!----------------------------------
           End
            -------------------------------->
            
           

<script>
$(function() {
    $("#imgTaskCustomize").attr("src", "/"+$("#imgTaskIamge").attr('alt'));
    $("#titleTaskCustomize").html($("#taskTitle").html());
    $(".titleFeature").html($("#taskTitle").html());
    $("#descriptionTaskCustomize").html($("#taskDescription").html()); 
    $("#imgPriorityTaskCustomize").attr("src", "/images/detail-page-img/star" + $("#imgPriority").attr("data-priority") + "-d.png");
    
    var $window = $(window);
    var windowsize = $window.width();

    if (windowsize < 767) {
        $(".mobileMenu").show();
    }
    checkForIphone();
});

function checkForIphone() {

    if ($("#hdnSessionValueTask").val() != '') {
        if ($("#hdnSessionValueTask").val() == "@HomeCareLibrary.Constants.ApplicationModeConstants.IPHONE_APP" || $("#hdnSessionValueTask").val() == "@HomeCareLibrary.Constants.ApplicationModeConstants.IPAD_APP") {

                $(".mobileMenu").hide();
            }
        }

    }
    </script>